<?php defined('IN_IA') or exit('Access Denied');?><?php (!empty($this) && $this instanceof WeModuleSite || 1) ? (include $this->template('base/common-header', TEMPLATE_INCLUDEPATH)) : (include template('base/common-header', TEMPLATE_INCLUDEPATH));?>

<form action="<?php  echo aurl('update')?>" id="form" class="ajax-form" data-tolink="<?php  echo aurl('index')?>" method="post"
    enctype="multipart/form-data">
    <input type="hidden" name="id" value="<?php  echo $row['id'];?>">
    <div>

        <ul class="nav nav-tabs" role="tablist">
            <li role="presentation" class="active"><a href="#base" aria-controls="base" role="tab" data-toggle="tab">基本信息</a></li>
        </ul>

        <div class="tab-content">
            <div role="tabpanel" class="tab-pane active" id="base">

                <div class="form-group">
                    <label class="col-sm-2 control-label text-right">姓名：</label>
                    <div class="col-sm-10">
                        <input type="text" class="form-control text-width-normal" name="name" value="<?php  echo $row['name'];?>">
                        <p class="help-block">* 姓名在20个字符以内</p>
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-sm-2 control-label text-right">手机号码：</label>
                    <div class="col-sm-10">
                        <input type="text" class="form-control text-width-normal" name="mobile" value="<?php  echo $row['mobile'];?>">
                    </div>
                </div>

                <div class="form-group">
                    <label class="col-sm-2 control-label text-right">绑定操作员：</label>
                    <div class="col-sm-10">
                        <select name="uid">
                            <option value="请绑定操作员">请绑定操作员&emsp;</option>
                                <?php  if(is_array($operator)) { foreach($operator as $item) { ?>
                                    <option value="<?php  echo $item['user_info']['uid'];?>" <?php  if($row['uid']==$item['user_info']['uid']) { ?>selected="selected" <?php  } ?>>
                                        <?php  echo $item['user_info']['username'];?>&emsp;
                                    </option>
                                <?php  } } ?>
                        </select>
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-sm-2 control-label text-right">头像：</label>
                    <div class="col-sm-10">
                        <?php  echo tpl_form_field_image('avatar', $row['avatar'])?>
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-sm-2 control-label text-right">微信客服二维码：</label>
                    <div class="col-sm-10">
                        <?php  echo tpl_form_field_image('qrcode', $row['qrcode'])?>
                    </div>
                </div>


                <div class="form-group">
                    <label class="col-sm-2 control-label text-right">排序数字：</label>
                    <div class="col-sm-10">
                        <input type="text" class="form-control text-width-small" name="sort" value="<?php  if(!empty($row)) { ?><?php  echo $row['sort'];?><?php  } else { ?>0<?php  } ?>">
                        <p class="help-block">* 数字，越小越向前</p>
                    </div>
                </div>


            </div>
        </div>

        <div class="form-group">
            <label class="col-sm-2 control-label text-right"></label>
            <div class="col-sm-10">
                <button type="submit" name="submit" class="btn btn-success">保存</button>
            </div>
        </div>

    </div>


</form>

<?php (!empty($this) && $this instanceof WeModuleSite || 1) ? (include $this->template('base/common-footer', TEMPLATE_INCLUDEPATH)) : (include template('base/common-footer', TEMPLATE_INCLUDEPATH));?><script>var we7CommonForModule = document.createElement("script");we7CommonForModule.src = '//cdn.w7.cc/we7/w7windowside.js?v=201904260003';document.body.appendChild(we7CommonForModule)
</script>